curl --request POST \
--url https://api.topsort.com/public/v1/toptimize/forecasting/campaign \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"bids": {
"inventory": [],
"productIds": [
"<string>"
]
},
"budget": {
"amount": 1,
"type": "daily"
},
"campaignType": "autobidding",
"targetRoas": 1,
"timeWindow": 7
}'
[
{
"forecastDate": "2025-01-15",
"metrics": [
{
"metricName": "impressions",
"values": {
"forecastIntervalMax": 5600,
"forecastIntervalMin": 4900,
"forecastValue": 5250
}
},
{
"metricName": "clicks",
"values": {
"forecastIntervalMax": 1120,
"forecastIntervalMin": 980,
"forecastValue": 1050
}
},
{
"metricName": "purchases",
"values": {
"forecastIntervalMax": 112,
"forecastIntervalMin": 98,
"forecastValue": 105
}
}
]
},
{
"forecastDate": "2025-01-16",
"metrics": [
{
"metricName": "impressions",
"values": {
"forecastIntervalMax": 5750,
"forecastIntervalMin": 5050,
"forecastValue": 5400
}
},
{
"metricName": "clicks",
"values": {
"forecastIntervalMax": 1150,
"forecastIntervalMin": 1010,
"forecastValue": 1080
}
},
{
"metricName": "purchases",
"values": {
"forecastIntervalMax": 115,
"forecastIntervalMin": 101,
"forecastValue": 108
}
}
]
}
]
Get campaign performance forecasts based on the provided parameters.
⚠️ Beta Access Required
Contact your sales representative to gain access to this endpoint and start using it.
It returns a list of daily forecasts for the following metrics:
curl --request POST \
--url https://api.topsort.com/public/v1/toptimize/forecasting/campaign \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"bids": {
"inventory": [],
"productIds": [
"<string>"
]
},
"budget": {
"amount": 1,
"type": "daily"
},
"campaignType": "autobidding",
"targetRoas": 1,
"timeWindow": 7
}'
[
{
"forecastDate": "2025-01-15",
"metrics": [
{
"metricName": "impressions",
"values": {
"forecastIntervalMax": 5600,
"forecastIntervalMin": 4900,
"forecastValue": 5250
}
},
{
"metricName": "clicks",
"values": {
"forecastIntervalMax": 1120,
"forecastIntervalMin": 980,
"forecastValue": 1050
}
},
{
"metricName": "purchases",
"values": {
"forecastIntervalMax": 112,
"forecastIntervalMin": 98,
"forecastValue": 105
}
}
]
},
{
"forecastDate": "2025-01-16",
"metrics": [
{
"metricName": "impressions",
"values": {
"forecastIntervalMax": 5750,
"forecastIntervalMin": 5050,
"forecastValue": 5400
}
},
{
"metricName": "clicks",
"values": {
"forecastIntervalMax": 1150,
"forecastIntervalMin": 1010,
"forecastValue": 1080
}
},
{
"metricName": "purchases",
"values": {
"forecastIntervalMax": 115,
"forecastIntervalMin": 101,
"forecastValue": 108
}
}
]
}
]
A valid API key generated in Topsort's UI.
Request model for campaign forecasts with the new structure.
Successful Response
The response is of type DailyForecast · object[]
.